import request from "@/utils/request.js";

export const addToOrder = (totalAmount) => {
    return request({
        url: '/user/order/addOrder',
        method: 'post',
        data: {totalAmount}
    })
}

export const addToOrderDetail = (orderDetailList) => {
    return request({
        url: '/user/orderDetail/addOrderDetail',
        method: 'post',
        data: {orderDetailList }
    })
}

export const getOrdersByPage=(pageSelect)=>{
    return request({
        url:'/user/order/getOrdersByPage',
        method:'get',
        params:pageSelect
    })
}